﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Reflection;
using System.Collections;

namespace SimpleRest.Serialization
{
    public class TypeCacheItem
    {
        public Type Target { get; set; }
        public Hashtable AssociatedProperties { get; set; }
        public bool IsCollection { get; set; }
        public bool IsPrimitive { get; set; }
        public Hashtable AssociatedAttributes { get; set; }

        public override string ToString()
        {
            return this.Target.FullName;
        }
        public override bool Equals(object obj)
        {
            if (obj is Type)
            {
                return (obj as Type).FullName.Equals(this.Target.FullName);
            }
            else
            {
                return false;
            }
        }
        public override int GetHashCode()
        {
            return base.GetHashCode();
        }
    }
}
